#
# Copyright (c) 2013 Juniper Networks, Inc. All rights reserved.
#

# -*- mode: python; -*-

import platform
if platform.system() == 'Darwin':
    Return()

Import('AgentEnv')
env = AgentEnv.Clone()

# test specific modifications
AgentEnv.MakeTestEnv(env)

lib_src = ['test_xml.cc', 'test_xml_validate.cc', 'test_xml_packet.cc']
env.Library('agent_test_xml', lib_src)

oper_lib_src = ['test_xml_oper.cc']
env.Library('agent_oper_test_xml', oper_lib_src)

env.Append(LIBPATH = env['TOP'] + '/vnsw/agent/test-xml')
env.Append(LIBS = 'agent_test_xml')
env.Append(LIBS = 'agent_oper_test_xml')

agent_suite = []
flaky_agent_suite = []
test_xml_dummy = AgentEnv.MakeTestCmdSrc(env, 'test_xml_dummy',
                                        [
                                         'test_xml_dummy.cc',
                                         '../pkt/test/test_pkt_util.o'
                                        ],
                                        flaky_agent_suite)

flaky_test = env.TestSuite('agent-flaky-test', flaky_agent_suite)
env.Alias('controller/src/vnsw/agent:flaky_test', flaky_test)

test = env.TestSuite('agent-test', agent_suite)
env.Alias('agent:agent_test', test)
Return('agent_suite')
